"""

.. module:: setup
.. moduleauthor:: @author: 

The purpose of this module is to configure py2exe.
   
.. seealso:: 

"""

# Imports
#
from distutils.core import setup
import py2exe

setup(
      # console - list of scripts to convert into console exes 
      console=['src/runtime/boot.py'],
      
      # windows - list of scripts to convert into GUI exes 
      windows=[],
      
      # service - list of module names containing win32 service classes 
      service=[],
      
      # com_server - list of module names containing com server classes 
      com_server=[],
      
      # ctypes_com_server - list of module names containing com server classes 
      ctypes_com_server=[],
      
      # zipfile - name of shared zipfile to generate; may specify a subdirectory; defaults to 'library.zip'. If zipfile 
      #           is set to None, the files will be bundled within the executable instead of 'library.zip'. 
      zipfile=None,
      
      # options - dictionary { "py2exe": { "opt1": val1, "opt2": val2, ... } } 
      options={
               "py2exe":{
                         # unbuffered - if true, use unbuffered binary stdout and stderr 
                         "unbuffered": True,
                         
                         # optimize - string or int of optimization level (0, 1, or 2) 
                         #            - 0 = don't optimize (generate .pyc)
                         #            - 1 = normal optimization (like python -O) 
                         #            - 2 = extra optimization (like python -OO).
                         #            See http://docs.python.org/distutils/apiref.html#module-distutils.util for more info. 
                         "optimize": 0,
                         
                         # includes - list of module names to include 
                         "includes": [],
                         
                         # packages - list of packages to include with subpackages 
                         "packages": ["encodings", 
                                      "Queue", 
                                      "xml.dom", 
                                      "json", 
                                      "BaseHTTPServer", 
                                      "threading", 
                                      "win32serviceutil", 
                                      "win32event",
                                      "zipfile",
                                      
                                      # include our base packages.
                                      #
                                      "datastore",
                                      "package",
                                      "runtime",
                                      "services"
                                      ],
                         
                         # ignores - list of modules to ignore if they are not found 
                         "ignores": [],

                         # excludes - list of module names to exclude 
                         "excludes": [],
                         
                         # dll_excludes - list of dlls to exclude 
                         "dll_excludes": [],
                         
                         # dist_dir - directory in which to build the final files 
                         "dist_dir": "./py2exeOutput",
                         
                         # typelibs - list of gen_py generated typelibs to include 
                         "typelibs": [],
                         
                         # compressed - (boolean) create a compressed zipfile 
                         "compressed": False,
                         
                         # xref - (boolean) create and show a module cross reference 
                         "xref": False,
                         
                         # bundle_files - bundle dlls in the zipfile or the exe. Valid values for bundle_files are: 
                         #                - 3 = don't bundle (default) 
                         #                - 2 = bundle everything but the Python interpreter 
                         #                - 1 = bundle everything, including the Python interpreter
                         "bundle_files": 1,
                         
                         # skip_archive - (boolean) do not place Python bytecode files in an archive, put them directly 
                         #                in the file system 
                         "skip_archive": False,
                         
                         # ascii - (boolean) do not automatically include encodings and codecs 
                         "ascii":  True
                         
                         # custom-boot-script - Python file that will be run when setting up the runtime environment 
                         # "custom-boot-script": ""
               }
      }
)